package com.yuting.server;

/**
 * @author cyt
 * @date 2020/7/2
 */
public interface ManageModule<T> {

    /**
     * add an element
     * @param t
     * @return
     */
    boolean add(T t);

    /**
     * delete an element
     * @param t
     * @return
     */
    boolean delete(T t);

    /**
     * modify an element
     * @param t
     * @return
     */
    boolean modify(T t);

    /**
     * search for an element
     * @param t
     * @return
     */
    T search(T t);

    /**
     * store the data into disk
     */
    void storeData();

    /**
     * read the data from file
     */
    void readData();

}
